$admin_width: 1080px;
$menu_width: 120px;
$standard_rounding: 0px;

p {
  font-size: 14px;
  line-height: 18px;
}
html {
  height: 100%;
}
body {
  height: 100%;
  box-sizing: border-box;
  font-family: Arial, sans-serif;
  line-height: 1.5em;
  color: #41403C;
  background: rgb(217, 217, 217);
}
acronym {
  cursor: help;
}
label[for] {
  cursor: pointer;
}
#admin_container,
#login_container {
  font-size: 13px;
  margin: 0px auto 15px auto;
  text-align: left;
  position: relative;
  margin-top: 15px;
  @include rounded($standard_rounding);
  a {
    color: #41403C;
    text-decoration: none;
  }
  #menu {
    a:hover {
      border-bottom: 0px;
    }
  }
  .hidden {
    display: none;
  }
}
#login_container {
  background: white;
  width: 620px;
}
#admin_container {
  width: $admin_width;
  margin: -5px auto 0px auto;
  height: 100%;
  @include faux_columns_2($menu_width, transparent, white);
  padding-left: 120px;
}
#page_container {
  background-color: white;
  padding: 1.5em 1em;
  position: relative;
  float: left;
  width: $admin_width - $menu_width;
  @include box-sizing(border-box);
  @include right-rounded($standard_rounding);
}
#content .field,
#content .form-actions {
  position: relative;
}
input.widest,
textarea.widest {
  width: 99%;
}
select.widest {
  max-width: 99%;
}
#records {
  float: left;
  width: 67.7%;
}
#actions {
  float: right;
  width: 30%;
  padding-left: 15px;
  padding-top: 0px;
  ul {
    margin: 0px 0px 18px 0px;
    padding: 0;
    list-style: none;
    &#current_locale {
      margin-top: 30px;
    }
  }
  li {
    margin-bottom: 10px;
    background-color: $action-background-colour;
    border: 1px solid $action-border-colour;
    padding: 9px;
    display: block;
    &:empty {
      display: none
    }
  }
}
#sort-status {
  padding: 5px 5px 5px 0px;
}
hr {
  border: 0;
  border-top: 1px solid #484743;
}

.errorExplanation {
  background-color: #FFB1B1;
  padding: 0px 5px 5px 30px;
  font-weight: bold;
  margin-top: 5px;
  margin-bottom: 5px;
  border: 1px solid red;
  h2 {
    color: red;
    text-transform: none;
    display: none;
  }
  p {
    font-weight: normal;
  }
}
.fieldWithErrors input,
.fieldWithErrors textarea {
  border: 1px solid red !important;
  background-color: #FFECF0 !important;
}
.fieldWithErrors iframe,
.fieldWithErrors .visual_editor_box {
  border-color: red !important;
}
#message,
.flash {
  padding: 8px 8px 8px 30px;
  margin-bottom: 15px;
  position: relative;
}
.flash_notice,
.flash_message {
  border: 1px solid #00A017;
  color: #00A017;
  @include icon('check-circle', green)
}
.flash_notice,
.flash_notice * {
  color: #00A017;
}
.flash_error,
.flash_alert {
  border: 1px solid #A00027;
  color: #A00027;
  @include icon('question-circle', red)
}
.flash.flash_notice #flash_close,
.flash.flash_error #flash_close,
.flash.flash_alert #flash_close {
  text-transform: lowercase;
  @include icon('times-circle', $icon_done_colour, 1.2em)
}
.flash.flash_message {
  background: #E0F5E0;
  padding: 9px;
  position: relative;
  margin-bottom: 32px;
  h2 {
    margin-top: 12px;
  }
}
.flash.flash_message.flash_message,
.flash_message * {
  color: #262719;
  font-size: 14px;
}
.flash a,
.flash a:hover {
  color: #e20003;
  border-bottom-color: #e20003;
}
.flash.flash_error a,
.flash.flash_error a:hover,
.flash.flash_alert a,
.flash.flash_alert a:hover {
  display: none;
}
noscript .flash.flash_error a,
noscript .flash.flash_error a:hover,
noscript .flash.flash_alert a,
noscript .flash.flash_alert a:hover {
  display: inline;
  font-weight: bold;
}
.flash #flash_close {
  background: none;
  border: none;
  color: #41403C;
  cursor: pointer;
  float: right;
  font-size: 1em;
  margin-top: 3px;
}
#content .visual_editor_box a,
#content .ui-tabs a {
  border-bottom: 0px none;
}
.index #content,
.splash #content {
  background-color: white;
  background-repeat: repeat-y;
}
#content {
  padding: 0px;
  background-color: white;
  a {
    border-bottom: 1px dotted #727272;
    &.locale {
      border-bottom: 0;
      display:inline;
    }
  }
  h1 {
    font-size: 18px;
    font-weight: lighter;
    text-align: center;
    border-bottom: 1px solid #99998B;
    padding-bottom: 10px;
  }
  h2 {
    font-size: 18px;
    color:#41403c;
    margin-bottom: 15px;
    margin-top: 10px;
    font-weight: bold;
  }
  form.edit_image {
    width: 70%;
    float: left;
  }
  #existing_image {
    float: right;
    width: 25%;
  }
  .actions {
    a {
      display: block;
      float: right;
      margin: 3px 3px;
      line-height: inherit;
      border-bottom: 0px none;
    }
  }
}
.less-important {
  color: #727272;
}
header,
footer,
nav {
  display: block;
}
#page_container .login #page h1 {
  margin: 0;
  padding: 5px;
  font-size: 20px;
  line-height:22px
}
#login_container {
  #page_container {
    background: transparent;
    width: 100%;
    div.remember_me label,
    label.inline {
      display: inline;
    }
    div.actions {
      margin-top: 12px;
    }
    div.remember_me {
      width: 300px;
      float: left;
    }
    div.forgot_password {
      float: right;
      width: 250px;
    }
  }
  header {
    background: #eaeaea;
    height: auto;
    float: none;
    width: 100%;
    @include top-rounded($standard_rounding);
    h1 {
      color: #41403c;
      vertical-align: middle;
      text-align: center;
      font-weight: bold;
      font-size: 18px;
      padding-bottom: 15px;
      line-height: 30px;
      padding-top: 15px;
    }
  }
  label {
    margin-top: 0px;
  }
  label,
  a {
    font-size: 14px;
  }
  .field {
    margin-bottom: 20px;
    &.remember_me,
    &.forgot_password {
      margin-bottom: 0px;
      margin-top: 0px;
    }
    &.forgot_password {
      text-align: right;
    }
    &.remember_me label {
      margin-top: 20px;
    }
  }
  #flash_container,
  .errorExplanation {
    margin-bottom: 12px;
  }
  /* Works in Firefox, Safari, Chrome, IE8+ */
  input.larger {
    background: image_url('refinery/text_field_background.png') repeat-x white;
    height: 31px;
  }
  input.larger:focus {
    background-position: 0px -41px;
  }
  .fieldWithErrors input.larger {
    background-position: 0px -82px;
    border: 1px solid red;
  }
}
div.field.checkbox_access {
  margin-top: 20px;
  ul.checkboxes li {
    margin-top: 3px;
  }
  .label_with_help a {
    font-weight: normal;
  }
}
#menu, {
  display: block;
  margin: 45px 0px 0px 0px;
  padding: 0px;
  position: absolute;
  background: transparent;
}
header {
  float: left;
  margin-bottom: 0px;
  width: $menu_width;
  a, a:hover {
    border-bottom: 0px none;
  }
  #logo {
    position: absolute;
    right: 20px;
    top: 25px;
  }
  h1, h1 a {
    color: white;
    font-size: 20px;
    font-weight: normal;
    margin-bottom: 0;
    padding-bottom: 4px;
    margin-top: 0;
  }
  p {
    color: white;
    font-size: 90%;
    padding: 0;
    margin: 0;
  }
}
#menu {
  display: block;
  position: relative;
  &.ui-sortable a {
    cursor: move;
  }
  &.ui-sortable-disabled a {
    cursor: pointer;
  }
  a {
    @include box-sizing(border-box);
    display: block;
    padding: 8px 16px;
    font-size: 14px;
    background-color: rgba(233, 233, 233, 1);
    margin-bottom: 1px;
    color: rgba(7, 112, 173, 1);
    font-weight: normal;
    position: relative;
    &.active, &:hover, &:focus {
      background-color: rgba(37, 169, 244, 1);
      color: white;
    }
    &.active {
      margin-left: -0.5em;
      font-weight: bold;
    }
  }

  a#menu_reorder,
  a#menu_reorder_done {
    height: 14px;
    width: 14px;
    margin-bottom: 0;
    padding: 6px;
    cursor: pointer;
    vertical-align: middle;
    text-align: center;
    float: right;
    @include box-sizing(content-box);
  }
  a#menu_reorder_done {
    background: white;
  }
}

pre {
  margin: 0;
  padding: 0;
}
.preview {
  color: #A3A093;
}
#site_link {
  display: block;
  color: #C2C2B3;
  float: left;
}
#site_link:hover {
  text-decoration: underline;
}
.filter {
  float: right;
}
#records {
  > ul, > #recent_activity > ul, > #recent_inquiries > ul,
  .pagination_container > ul, .pagination_frame > ul {
    margin-left: 0;
    margin-top: 0;
    padding-left: 0;
  }
  > ul li, > #recent_activity > ul li, > #recent_inquiries > ul li,
  .pagination_container > ul li, .pagination_frame > ul {
    list-style: none;
    padding: 0px 5px;
    vertical-align: top;
    margin-bottom: 2px;
    line-height: 35px;
    position: relative;
  }
  > #recent_activity > ul li, > #recent_inquiries > ul li {
    max-height: 35px;
  }
}
#recent_activity li a, #recent_inquiries li a {
  overflow: hidden;
  white-space: nowrap;
  -o-text-overflow: ellipsis;
  -ms-text-overflow: ellipsis;
  text-overflow: ellipsis;
}
#content #records {
  > ul li .actions a, .pagination_container > ul li .actions a {
    line-height: 29px;
  }
}
#records {
  ul {
    &.clickable {
      li {
        padding: 0px;
        margin-bottom: 0px;
        a {
          padding: 0px 5px;
          vertical-align: top;
          margin-bottom: 2px;
          line-height: 35px;
          display: block;
          border-bottom: 0px none;
        }
      }
    }
  }
  .left-column {
    float: left;
    width: 65%;
    img {
      vertical-align: bottom;
      margin-top: 1px;
      margin-right: 5px;
    }
  }
  .right-column {
    float: right;
    width: 34%;
    text-align: right;
  }
  .on {
    background-color: #EAEAEA;
  }
  .off, .on-hover {
    background-color: white;
  }
  ul.empty {
    display: none;
  }
  ul#sortable_list, ul.sortable_list {
    margin-top: 6px;
  }
  > #recent_activity, > #recent_inquiries {
    float: left;
    width: 48%;
  }
  > #recent_inquiries {
    margin-left: 21px;
  }
}
#records.one_list > #recent_activity, #records.one_list > #recent_inquiries {
  width: 100%;
}
#pagination ul a:hover, #pagination .on {
  background: image_url('refinery/hover-gradient.jpg') repeat-x bottom #D4D4C6;
}
#records.tree ul li ul, .tree ul li ul {
  padding: 0;
}
#records.tree ul li, .tree ul li {
  margin: 0px;
  padding: 4px 0 0 40px;
  background: image_url('refinery/branch.gif') no-repeat 15px 0px;
}
#records.tree li.record ul {
  margin-left: 0;
}
#records.tree .on-hover, #pagination ul.tree a:hover, #pagination .tree .on {
  background: image_url('refinery/branch.gif') no-repeat 15px 0px;
}
#records.tree ul li.branch_start, .tree ul li.branch_start {
  background-image: image_url('refinery/branch-start.gif');
}
#records.tree ul li.branch_end, .tree ul li.branch_end {
  background-image: image_url('refinery/branch-end.gif');
}
#records.tree li {
  line-height: 25px;
}
#records.tree li span.spacing, .tree li span.spacing {
  display: none;
}
#records.tree ul li > div:hover, .tree ul li > div:hover {
  background-color: #EAEAEA;
}
#sortable_list.reordering > li, .sortable_list.reordering > li {
  cursor: move;
}
#records h2, #actions h2 {
  margin-top: 0px;
}
.pagination {
  background-color: #C9DAE2;
  padding: 5px 5px 4px 5px;
  margin: 10px 0px;
  em {
    font-weight: bold;
    font-style: normal;
    padding: 0px 6px;
  }
}
.pagination {
  .disabled {
    color: #A8B9C1;
  }
  a, #content a, .current, .disabled, em  {
    padding: 7px;
    line-height: 20px;
    border-bottom: 0px none;
  }
  .current, a:hover, em {
    background: #A8B9C1;
  }
}
textarea {
  line-height: 20px;
  padding: 5px;
}
.field-couple {
  margin-bottom: 20px;
}
.submit {
  border: inherit;
  width: auto;
  height: 25px;
}
label, .label_with_help {
  margin-bottom: 5px;
  font-weight: bold;
  margin-top: 20px;
  display: block;
}
label.input_label {
  font-size: inherit;
  margin-bottom: inherit;
  display: inline;
  font-weight: normal;
  margin-top: inherit;
}
small label {
  font-size: inherit;
  font-weight: inherit;
  display: inherit;
}
label.stripped {
  float: none;
  display: inline;
  font-weight: normal;
  font-size: 1em;
  margin: 0px;
  padding: 0px;
}
#body_field {
  float: left;
  width: 60%;
}
.no_side_body {
  width: 72% !important;
}
#side_body_field {
  float: left;
  width: 38%;
  margin-left: 18px;
}
#body_field textarea, #side_body_field textarea {
  width: 99%;
}
.record .title span {
  line-height: 30px;
}

#records.files .record .title, #dialog_main #resource_file_area .pages_list ul li a.page_link {
  display:inline-block;
  padding-left:24px;
  min-height:16px;
  background-repeat:no-repeat;
  background-position:left;
  @include icon('file-o', blue)
}
#dialog_main #resource_file_area .pages_list ul li a.page_link{
  background-position:5px center;
  display:block;
}
#records.files .record .title.pdf, #dialog_main #resource_file_area .pages_list ul li a.page_link.pdf {
  @include icon('file-pdf-o')
}
#records.files .record .title.jpg,
#records.files .record .title.gif,
#records.files .record .title.jpeg,
#records.files .record .title.png,
#records.files .record .title.tiff,
#dialog_main #resource_file_area .pages_list ul li a.page_link.jpg,
#dialog_main #resource_file_area .pages_list ul li a.page_link.jpeg,
#dialog_main #resource_file_area .pages_list ul li a.page_link.gif,
#dialog_main #resource_file_area .pages_list ul li a.page_link.png,
#dialog_main #resource_file_area .pages_list ul li a.page_link.tiff {
  @include icon('file-image-o');
}

#records.files .record .title.doc, #records.files .record .title.pages, #records.files .record .title.docx, #dialog_main #resource_file_area .pages_list ul li a.page_link.doc, #dialog_main #resource_file_area .pages_list ul li a.page_link.docx, #dialog_main #resource_file_area .pages_list ul li a.page_link.pages {
  @include icon('file-word-o');
}
#records.files .record .title.ppt, #records.files .record .title.keynote, #dialog_main #resource_file_area .pages_list ul li a.page_link.ppt, #dialog_main #resource_file_area .pages_list ul li a.page_link.keynote {
  @include icon('file-powerpoint-o');
}
#records.files .record .title.xls, #records.files .record .title.numbers, #dialog_main #resource_file_area .pages_list ul li a.page_link.xls, #dialog_main #resource_file_area .pages_list ul li a.page_link.numbers {
  @include icon('file-excel-o');
}
#records.files .record .title.zip, #records.files .record .title.rar, #dialog_main #resource_file_area .pages_list ul li a.page_link.zip, #dialog_main #resource_file_area .pages_list ul li a.page_link.rar {
  @include icon('file-zip-o');
}
#records.files .record .title.mp3, #records.files .record .title.wav, #records.files .record .title.aiff, #records.files .record .title.m4a, #dialog_main #resource_file_area .pages_list ul li a.page_link.mp3, #dialog_main #resource_file_area .pages_list ul li a.page_link.wav, #dialog_main #resource_file_area .pages_list ul li a.page_link.aiff, #dialog_main #resource_file_area .pages_list ul li a.page_link.m4a {
  @include icon('file-audio-o');
}
#records .actions {
  position: absolute;
  right: 0px;
  top: 0px;
  width: 120px;
  text-align: right;
  display: block;
  line-height: 28px;
}
#records.tree.icons .title {
  display: block;
  margin: 0 120px 0 20px;

  &.toggle {
    cursor: pointer;
  }
}
#records.tree .actions {
  line-height: 22px;
  top: 1px;
}
.published {
  width: 25px;
  text-align: center;
}
#content #records.tree > ul li .actions a {
  margin: 3px 3px 0px 3px;
  line-height: 24px;
}
.actions a * {
  padding: 4px 4px 1px 4px;
}
.actions a img {
  vertical-align: middle;
  padding: 2px 4px 4px 4px;
}
#records.tree .actions a img {
  padding-top: 4px;
}
#records.tree li span.item {
  display: block;
  float: left;
  width: 16px;
  height: 16px;
  margin: 3px 3px 0 0;
  @include icon('file-o', $icon_page_colour);

  &.toggle {
    cursor: pointer;
    @include icon('folder',$icon_folder_colour);
  }
  &.toggle.expanded {
    @include icon('folder-open',$icon_folder_colour);
  }
}
#records.tree li.loading > div > span.icon {
  @include icon('spinner');
}
#image_grid .actions a img {
  padding: 4px 4px 1px 4px;
  vertical-align: top;
}

.actions a.reorder_anchor:hover {
  background: inherit !important;
  cursor: move;
}
#other_records {
  width: 68%;
}
#common_actions {
  margin: 0;
  padding: 0;
  li {
    margin: 0;
    list-style: none;
    padding: 5px 0px 5px 0px;
  }
    a {
      font-weight: bold;
    }
}
.larger {
  font-size: 200%;
}
.brown_border {
  border: 1px solid #99998B;
}
#inquiry, .inquiry {
  border-collapse: collapse;
  width: 100%;
}
#inquiry td, .inquiry td {
  border-bottom: 1px solid #CCCCCC;
  padding: 7px;
}
#inquiry tr:last-child td, .inquiry tr:last-child td {
  border-bottom: 0px;
}
#inquiry td label.stripped, .inquiry td label.stripped {
  font-weight: bold;
}
body.dialog {
  background: #FFF;
}
body.dialog, body.visual_editor_dialog {
  text-align: left;
}
body.dialog form {
  width: 100% !important;
}
.visual_editor_dialog_table {
  height: 250px;
}
.no_picked_image_selected {@include icon('warning', $icon_warning_colour)}
.dialog {
  #dialog_main {
    float: left;
    margin-left: 130px;
    min-height: 405px;
    width: 696px;
  }
  span.radio {
    display: block;
    line-height: 18px;
    padding: 6px 0px;
  }
  span.radio * {
    cursor: pointer;
    font-weight: bold;
  }
  #dialog_menu_left {
    position: fixed;
    left: 30px;
    top: 9px;
    width: 130px;
  }
  #existing_image_content {
    position: relative;
    height: 300px;
    padding: 12px;
  }
  #existing_image_area_content {
    margin-top: 28px;
    ul {
      margin: 0px;
      padding: 0px;
      li {
        list-style: none;
        padding: 0px;
        margin: 0px 2px 0px 0px;
        float: left;
        height: 114px;
        max-height: 114px;
        width: 114px;
        max-width: 114px;
        overflow: hidden;
        cursor: pointer;
        text-align: center;
        vertical-align: middle;
        img {
          border: 4px solid transparent;
        }
        &.selected img {
          border: 4px solid #22A7F2;
        }
      }
    }
  }
  #existing_image_size_area {
    margin-top: 18px;
    ul {
      margin: 0px;
      padding: 10px 0px 0px 0px;
      li {
        float: left;
        list-style: none;
        margin: 0px 18px 0px 0px;
        text-align:center;
        a {
          display: block;
          border: 1px solid #999999;
          font-size: 10px;
        }
        &.selected {
          a {
            border-color: #22A7F2;
            background: #22A7F2;
            color: white;
            font-weight: bold;
          }
        }
      }
    }
  }
  #existing_image_size_area {
    #image_dialog_size_0 a { height: 30px; width: 30px; line-height: 30px; margin-top: 10px }
    #image_dialog_size_1 a { height: 50px; width: 50px; line-height: 50px; margin-top:  0px }
    #image_dialog_size_2 a { height: 70px; width: 70px; line-height: 70px; margin-top:-10px }
    #image_dialog_size_3 a { height: 90px; width: 90px; line-height: 90px; margin-top:-20px }
  }
  #content {
    padding: 0px;
  }
}
#upload_image_area, #upload_resource_area {
  padding: 12px;
}
.visual_editor_dialog #page {
  width: 940px;
  padding: 6px;
}
#dialog_main {
  .pagination {
    margin: 0px;
    position: fixed;
    bottom: 5px;
    right: 12px;
    z-index: 1000;
  }
  .pages_list {
    width: 100%;
    padding-bottom: 40px;
    ul {
      margin: 0px 12px 0px 12px;
      padding: 0px;
      li {
        cursor: pointer;
        line-height: 24px;
        list-style: none;
        a {
          display: block;
          padding: 3px 3px 3px 27px;
          text-decoration: none;
          border-bottom: none;
          border: 1px solid transparent;
        }
        &:hover {
          background-color: #C9DAE2;
        }
      }
      li.child a {
        padding-left: 27px;
      }
      li.child1 a {
        padding-left: 47px;
      }
      li.child2 a {
        padding-left: 67px;
      }
      li.child3 a {
        padding-left: 87px;
      }
      li.child4 a {
        padding-left: 107px;
      }
    }
  }
  .actions {
    margin-right: 48px;
  }
  .pages_list .linked a, .pages_list .linked a:hover {
    border: 1px solid #00A017;
    color: #00A017;
    @include icon('check-circle', green);
  }
  .pages_list .linked a em {
    color: #00A017;
  }
  #web_address_area, #dialog_main #email_address_area {
    padding: 12px;
  }
}
#link_title {
  margin-top: 12px;
  label {
    margin: 3px 0px 0px 0px !important;
    width: 130px;
    display: block;
    float: left;
  }
  input {
    width: 770px;
  }
}
ul#menu.reordering_menu li a {
  cursor: move;
}
.cancel-search {
  float: right;
}
.search_form {
  position: relative;
  .button, .button-wrapper {
    position: absolute;
    right: 0px;
    top: 2px;
  }
}
form input[type=submit]:hover {
  background: #65c3f7;
}
.clearfix:after {
  content:".";
  display:block;
  height:0;
  clear:both;
  visibility:hidden;
}
.clearfix {display:inline-block;}
/* Hide from IE Mac \*/
.clearfix {display:block;}
/* End hide from IE Mac */
/*
Firefox Dotted Line Fix
  - http://sonspring.com/journal/removing-dotted-links
*/
a:focus {
  outline: none;
}
a img {
  border: 0px none;
}


/* page parts */

ul#page_parts, 
ul#page_parts_controls {
  margin: 0;
  padding: 0;
}

ul#page_parts {
  float: left;
  width: 92%;
  z-index: 1;
}

ul#page_parts_controls {
  float: right;
  margin: 20px 3px 0 0;
  z-index: 2;

  li {
    list-style: none;
    float: right;
    margin: 0 3px;

    a {
      border: 0px none;
    }
  }
}


#page-tabs.ui-sortable.reordering {
  li {
    cursor: move;
    a {
      cursor: move;
    }
  }
}
#page_part_editors {
  clear:left;
}

/* dialog stuff */
#dialog_frame {
  width:952px;
  height:460px;
  padding: 0px;
  border: 0px solid #F2F1ED;
}
.visual_editor_hideables {
  display: none;
}
#content .form-actions, .wym_dialog .form-actions, .ui-dialog .form-actions {
  @include form-actions;
}
.dialog form {
  margin-bottom: 45px;
}
.dialog .dialog_area > div > .field label:first-child, .dialog .dialog_area > div > label:first-child {
  margin-top: 0px;
}
.visual_editor_dialog .form-actions, #content.form-actions.dialog-form-actions, .ui-dialog .form-actions {
  margin-top: 16px;
}
#content .form-actions .form-actions-left, #content .form-actions .form-actions-right,
  .visual_editor_dialog .form-actions .form-actions-left, .visual_editor_dialog .form-actions .form-actions-right,
  .ui-dialog .form-actions .form-actions-left, .ui-dialog .form-actions .form-actions-right {
  position: absolute;
  top: 10px;
}
#content .form-actions .form-actions-left, .visual_editor_dialog .form-actions .form-actions-left, .ui-dialog .form-actions .form-actions-left {
  left: 10px;
}
#content .form-actions .form-actions-right, .visual_editor_dialog .form-actions .form-actions-right, .ui-dialog .form-actions .form-actions-right {
  right: 10px;
}
#content .form-actions .save-loader {
  position: absolute;
  right: -24px;
  top: 4px;
}
.visual_editor_dialog .form-actions, .ui-dialog .form-actions {
  border: 0px none;
  border-top: 1px solid #E8E8E8;
}
#dialog_iframe {
  position: relative;
}
#dialog_container #content .form-actions, .ui-dialog .form-actions, .dialog_container .form-actions {
  position: absolute;
  bottom: 0px;
  left: 0px;
  right: 0px;
  border-right: 0px;
  border-left: 0px;
  border-bottom: 0px;
  width: auto;
}
#dialog_container.dialog.iframed #content .form-actions {
  position: fixed;
}
body.dialog #content .search_form {
  float: right;
  width: auto !important;
  min-width: 300px;
  margin-bottom: 0px;
}
#existing_image_area {
  padding-top:6px;
}
.ui-dialog div.field {
  margin: 0px 10px;
}
#dialog_container, .dialog_container {
  margin: 0px;
  padding: 12px;
}
ul#image_grid, .pagination_container > ul#image_grid {
  width: 100%;
  padding: 0px;
  margin: 10px 0px 15px 0px;
}
ul#image_grid li, .pagination_container > ul#image_grid li {
  position: relative;
  float: left;
  margin: 0px 12px 12px 0px;
  padding: 0px;
  width: 149px;
  height: 186px;
  max-width: 149px;
  max-height: 186px;
  text-align: center;
  overflow: hidden;
}
ul#image_grid li.image_3 {
  margin-left: 0px;
  margin-right: 0px;
}
#records ul#image_grid li .actions {
  top: auto;
  bottom: 0px;
}
#records ul#image_grid li .actions a {
  line-height: 24px;
}
ul#image_grid li.row-end {
  margin-right: 0px;
  float: right;
}
ul#image_grid li a {
  border: 0 none;
}
ul#image_grid li p {
  margin: 3px 0;
}
ul#image_grid li span.actions {
  width: 100%;
}
ul.checkboxes {
  margin: 0px;
  padding: 0px;
}
ul.checkboxes li {
  list-style: none;
}
.label_inline_with_link label {
  float: left;
  margin-right: 6px;
}
.label_inline_with_link a {
  border: 0px none;
  margin-top: 19px;
  line-height: 17px;
  float: left;
}
.label_inline_with_link a img {
  vertical-align: middle;
}
.remove_picked_image {
  margin-top:8px;
  display:inline-block;
  width:auto;
}
#new_page_part_dialog .field {
  padding: 0px 10px;
}
.hide-overflow {
  overflow: hidden;
}
#remove_resource {
  margin-top:8px;
  display:inline-block;
  width:auto;
}
.visual_editor_dialog_paste .field textarea {
  width: 98%;
}
.ui-dialog .visual_editor_dialog_paste .field, .ui-dialog .visual_editor_dialog_paste .field textarea {
  margin: 0px 0px 45px 0px;
  height: 300px;
}
input.button, a.button, #content a.button, span.button-wrapper, span.button-wrapper input {
  cursor:pointer;
  background: #22a7f2;
  color: white;
  padding: 0px 14px 0px 14px;
  font-size: 14px;
  line-height: 24px;
  height: 24px;
  display: inline-block;
  border: 0px none;
  margin-top: 0px;
  margin-bottom: 0px;
}
/* for those pesky IE browsers */
span.button-wrapper {
  padding: 0px;
}
span.button-wrapper input {
  display: inherit;
}
/* fixes firefox display */
input.button {
  padding-bottom: 3px;
}
input.button.close_dialog, a.button.close_dialog, #content a.button.close_dialog, span.button-wrapper.close_dialog, span.button-wrapper.close_dialog input {
  background: #bcbcbc;
}
input.button:hover, a.button:hover, #content a.button:hover, span.button-wrapper:hover, span.button-wrapper:hover input {
  background:#62bef2;
}
input.button.close_dialog:hover, a.button.close_dialog:hover, #content a.button.close_dialog:hover, span.button-wrapper.close_dialog:hover {
  background: #cdcdcd;
}
input.button:active, a.button:active, #content a.button:active, span.button-wrapper:active, span.button-wrapper:active input {
  background: #004a8f;
}
input.button.close_dialog:active, a.button.close_dialog:active, #content a.button.close_dialog:active, span.button-wrapper.close_dialog:active,  span.button-wrapper.close_dialog:active input {
  background: #808080;
}
.visual_editor_dialog a.button.visual_editor_cancel.close_dialog {
  margin-left: 6px;
}
#content a.button.close_dialog:active {
  color: white;
}
.form-actions a.confirm-delete, #content .form-actions a.confirm-delete {
  background: #ee1100;
  position: absolute;
  right: 0px;
}
.form-actions a.confirm-delete:hover, #content .form-actions a.confirm-delete:hover {
  background: #ff3322;
}
.form-actions a.confirm-delete:active, #content .form-actions a.confirm-delete:active {
  background: #bb0000;
}
.field input[type=text], .field input[type=password], .field input[type=email], .field input[type=tel], .field input[type=number], .field textarea {
  border: 1px solid #7f9db9;
  padding: 0.4% 0.5%;
  line-height: 20px;
  display: block;
}
/* ## Advanced Page Options --------------------------------------------- */
#more_options_field {
  span#draft_field {float: right;}
}
#more_options{
  overflow:hidden;
}
.hemisquare {
  padding: 10px;
  margin: 0px 0px;
  margin-left: 10px;
  float: left;
  width: 45%;
  &.right_side {
      float: right;
  }
  input, textarea, select {
    margin: 7px 0px;
  }
  textarea {
    margin-bottom: 0px;
  }
  label {
    margin: 0px;
  }
  small {
    font-size: 0.9em;
  }
}
#content .hemisquare h2 {
  margin-top: 0px;
}
#content .hemisquare .field {
  margin: 0 0 20px 0px;
  width: 98%;
}
.label_with_help {
  vertical-align: middle;
}
.label_with_help label, .label_with_help span.help, .label_with_help img.help {
  display: inline;
}
.label_with_help img.help {
  vertical-align: middle;
}
.label_with_help span.help {
  font-weight: normal;
  margin-left: 3px;
  border-bottom: 1px dotted #727272;
  cursor: help;
}
#more_options_field {
  position: relative;
}

.nothing_selected {
  width: auto;
  margin-bottom: 12px;
  display: inline-block;
}
#upgrade_wrapper li a {
  line-height: 20px;
}
/* resource-picker */
#resource_actions {
  float: right;
  margin-right: 20px;
}

/* Locale picker */
#switch_locale_picker {
  margin: 0px;
  padding: 0px;
  li {
    float: left;
    padding: 0px;
    margin: 0;
    list-style: none;
    a {
      background-color: #cdcdcd;
      background-position: 12px;
      background-repeat: no-repeat;
      border-bottom: 0;
      border-right: solid 1px white;
      margin-bottom: 1px;
      display: block;
      padding: 7px 3px 3px 3px;
      line-height: 0;
      &:hover {
        background-color: #cae7fb;
      }
      &:active {
        background-color: #22A7F2;
      }
    }
    &:first-child a {
      border-radius-left: 5px;
      -moz-border-radius-topleft: 5px;
      -moz-border-radius-bottomleft: 5px;
      -webkit-border-top-left-radius: 5px;
      -webkit-border-bottom-left-radius: 5px;
    }
    &:last-child a {
      border-radius-right: 5px;
      -moz-border-radius-topright: 5px;
      -moz-border-radius-bottomright: 5px;
      -webkit-border-top-right-radius: 5px;
      -webkit-border-bottom-right-radius: 5px;
    }
    &.selected a {
      background-color: #65c3f7;
    }
  }
}
#locale_picker {
  li {
    list-style: none;
    margin: 0;
    a {
      background-color: #cdcdcd;
      background-position: 12px;
      background-repeat: no-repeat;
      border: 0;
      border-bottom: solid 1px white;
      display: block;
      padding: 3px 14px 3px 9px;
      position: relative;
      &:hover {
        background-color: #cae7fb;
      }
      &:active {
        background-color: #22A7F2;
      }
      span.action {
        border-bottom: 1px dotted #727272;
        position: absolute;
        right: 9px;
        top: 5px;
      }
    }
    &:first-child a {
      border-radius-top: 5px;
      -moz-border-radius-topleft: 5px;
      -moz-border-radius-topright: 5px;
      -webkit-border-top-left-radius: 5px;
      -webkit-border-top-right-radius: 5px;
    }
    &:last-child a {
      border-radius-bottom: 5px;
      -moz-border-radius-bottomleft: 5px;
      -moz-border-radius-bottomright: 5px;
      -webkit-border-bottom-left-radius: 5px;
      -webkit-border-bottom-right-radius: 5px;
    }
  }
  #current_locale,
  #other_locales {
    margin: 0;
  }
  #current_locale li {
    a {
      background-color: #65c3f7;
    }
  }
}
.locale_marker {
  font-size:8px;
  display: inline;
  .fa-stack .fa-comment {color: $icon_locale_colour; font-size: 24px;}
}

#content #records .title .preview a.locale {
  border-bottom: 0px none;
}
/* AJAX pagination */
.pagination_container {
  position: relative;
}
.pagination_frame {
  padding: 0;
  width: 100%;
  right: auto;
  -moz-transition: all 0.3s ease-in-out;
  -o-transition: all 0.3s ease-in-out;
  -webkit-transition: all 0.3s ease-in-out;
  transition: all 0.3s ease-in-out;
}
.pagination_container > div.pagination_frame {
  top: 40px;
}
.pagination_frame.frame_left {
  left: -3000px;
}
.pagination_frame.frame_right {
  left: 3000px;
  -moz-transition: all 0.3s ease-in-out;
  -o-transition: all 0.3s ease-in-out;
  -webkit-transition: all 0.3s ease-in-out;
  transition: all 0.3s ease-in-out;
}
.pagination_frame.frame_center {
  left: 0;
}
.pagination_frame li {
  position: relative;
  padding-left: 5px;
}
a.information:hover {
  background: #22a7f2;
}
/* dubiously in here */
.current_image_link {
  display: inline-block;
  width: auto;
}
.label {
  padding: 1px 3px 2px;
  font-size: 9.75px;
  font-weight: bold;
  color: #ffffff;
  text-transform: uppercase;
  white-space: nowrap;
  background-color: #bfbfbf;
  margin-right: 0.25em;
  &.important{
    background-color: #c43c35;
  }
  &.warning{
    background-color: #f89406;
  }
  &.success{
    background-color: #46a546;
  }
  &.notice{
    background-color: #62cffc;
  }
}
